Binary XML refers to any specification which defines the compact representation of XML (Extensible Markup Language) in a binary format. While there are several competing formats, none has been widely adopted by a standards organization or accepted as a de facto standard. Using a binary XML format generally reduces the verbosity of XML documents thereby also reducing the cost of parsing,[1] but hinders the use of ordinary text editors and third-party tools to view and edit the document. Binary XML is typically used in applications where standard XML is not an option due to performance limitations, but the ability to convert the document to and from a form which is easily viewed and edited is valued. Other advantages may include enabling random access and indexing of XML documents.
The major challenge for binary XML is to create a single, widely adopted standard. The International Organization for Standardization (ISO) and the International Telecommunications Union (ITU) published the Fast Infoset standard in 2007 and 2005, respectively. The World Wide Web Consortium (W3C) has produced the first draft of the EXI format specification. Another standard (ISO/IEC 23001-1), known as Binary MPEG format for XML (BiM), has been standardized by the ISO in 2001. BiM is used by many ETSI standards for Digital TV and Mobile TV. The Open Geospatial Consortium also provides a Binary XML Encoding Specification (currently a Best Practice Paper) optimized for geo-related data (GML).
Alternatives to binary XML include using traditional file compression methods on XML documents (for example gzip); or using an existing standard such as ASN.1. Traditional compression methods, however, offer only the advantage of compression, without the advantage of decreased parsing time or random access. ASN.1 is being used as the basis of Fast Infoset, which is one binary XML standard. There are also hybrid approaches (e.g., VTD-XML) that attach a small index file to an XML document to eliminate the overhead of parsing.[2]
Projects and file formats which use binary XML include:
Other projects that have functionality related to (or competing with) binary representations include: